<?php

namespace app\api\controller\god;

use app\common\controller\Api;

// 院校信息
class College extends Api
{
    protected $noNeedRight = '*';
    protected $noNeedLogin = ['lists'];

    protected $model = null;

    public function _initialize()
    {
        parent::_initialize();
        $this->model = model('College');
    }

    public function lists()
    {
        $params = $this->request->param();
        $lists = $this->model->field('id,co_name, co_name as name,exam_area,co_code,stu_stop,status')
            ->where('status', 'normal') // 状态正常
            ->where('stu_stop', 'normal')  // 未停止招生
            ->select();

        $this->success('查询成功', $lists);

    }

}